package com.varian.cloud.config;

import com.varian.tool.Func;
import com.varian.tool.enums.EnvironmentProfileEnum;
import feign.Logger;
import org.springframework.boot.autoconfigure.AutoConfiguration;
import org.springframework.context.annotation.Bean;

/**
 * @author ben
 * @since 2024/6/23
 */
@AutoConfiguration
public class CloudAutoConfig {

    @Bean
    public Logger.Level feignLoggerLevel() {
        return Func.getProfile().equals(EnvironmentProfileEnum.PROD) ? Logger.Level.BASIC : Logger.Level.FULL;
    }
}
